//
//  CustomTableViewCell.m
//  IQKeyboardManager
//
//  Created by chenleping on 2018/11/22.
//  Copyright © 2018年 梁森. All rights reserved.
//

#import "CustomTableViewCell.h"

@implementation CustomTableViewCell

+ (instancetype)cellWithTableView:(UITableView *)tableView{
    NSString * cellid = NSStringFromClass([self class]);
    id cell = [tableView dequeueReusableCellWithIdentifier:cellid];
    if (cell == nil) {
        cell = [[self alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:cellid];
    }
    return cell;
}
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        [self setUpChildControl];
    }
    return self;
}
- (void)setUpChildControl{
    UITextField * textField = [UITextField new];
    [self addSubview:textField];
    textField.frame = CGRectMake(30, 0, 200, 30);
    textField.placeholder = @"请输入文字...";
    textField.backgroundColor = [UIColor lightGrayColor];
}
@end
